package org.cgc.gui;

import java.awt.Graphics;
import java.awt.Graphics2D;
import java.util.List;

import javax.swing.JPanel;

import org.cgc.obj.Graph;
import org.cgc.obj.GraphColoringInfo;

public class GCPanel extends JPanel {
		
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private GraphView gv;
	
	public GCPanel(Graph graph, GraphColoringInfo gci, List<Integer> selected) {
		gv = new GraphView(graph, gci, selected, 780, 500);
	}

	@Override
	protected void paintComponent(Graphics g) {
		super.paintComponent(g);
		Graphics2D g2 = (Graphics2D)g;
		gv.draw(g2);
	}
	
	public void paint() {
		repaint();
	}

	public GraphView getGv() {
		return gv;
	}
}
